package edu.hcmiu.portal.service.base;

import com.liferay.portal.PortalException;
import com.liferay.portal.SystemException;
import com.liferay.portal.kernel.annotation.BeanReference;
import com.liferay.portal.kernel.dao.orm.DynamicQuery;
import com.liferay.portal.util.PortalUtil;

import edu.hcmiu.portal.model.hook_user;
import edu.hcmiu.portal.service.hook_activityLocalService;
import edu.hcmiu.portal.service.hook_activityService;
import edu.hcmiu.portal.service.hook_categoryLocalService;
import edu.hcmiu.portal.service.hook_categoryService;
import edu.hcmiu.portal.service.hook_taglistLocalService;
import edu.hcmiu.portal.service.hook_taglistService;
import edu.hcmiu.portal.service.hook_userLocalService;
import edu.hcmiu.portal.service.hook_userService;
import edu.hcmiu.portal.service.persistence.hook_activityPersistence;
import edu.hcmiu.portal.service.persistence.hook_categoryPersistence;
import edu.hcmiu.portal.service.persistence.hook_taglistPersistence;
import edu.hcmiu.portal.service.persistence.hook_userPersistence;

import java.util.List;


public abstract class hook_userLocalServiceBaseImpl
    implements hook_userLocalService {
    @BeanReference(name = "edu.hcmiu.portal.service.hook_activityLocalService.impl")
    protected hook_activityLocalService hook_activityLocalService;
    @BeanReference(name = "edu.hcmiu.portal.service.hook_activityService.impl")
    protected hook_activityService hook_activityService;
    @BeanReference(name = "edu.hcmiu.portal.service.persistence.hook_activityPersistence.impl")
    protected hook_activityPersistence hook_activityPersistence;
    @BeanReference(name = "edu.hcmiu.portal.service.hook_categoryLocalService.impl")
    protected hook_categoryLocalService hook_categoryLocalService;
    @BeanReference(name = "edu.hcmiu.portal.service.hook_categoryService.impl")
    protected hook_categoryService hook_categoryService;
    @BeanReference(name = "edu.hcmiu.portal.service.persistence.hook_categoryPersistence.impl")
    protected hook_categoryPersistence hook_categoryPersistence;
    @BeanReference(name = "edu.hcmiu.portal.service.hook_taglistLocalService.impl")
    protected hook_taglistLocalService hook_taglistLocalService;
    @BeanReference(name = "edu.hcmiu.portal.service.hook_taglistService.impl")
    protected hook_taglistService hook_taglistService;
    @BeanReference(name = "edu.hcmiu.portal.service.persistence.hook_taglistPersistence.impl")
    protected hook_taglistPersistence hook_taglistPersistence;
    @BeanReference(name = "edu.hcmiu.portal.service.hook_userLocalService.impl")
    protected hook_userLocalService hook_userLocalService;
    @BeanReference(name = "edu.hcmiu.portal.service.hook_userService.impl")
    protected hook_userService hook_userService;
    @BeanReference(name = "edu.hcmiu.portal.service.persistence.hook_userPersistence.impl")
    protected hook_userPersistence hook_userPersistence;

    public hook_user addhook_user(hook_user hook_user)
        throws SystemException {
        hook_user.setNew(true);

        return hook_userPersistence.update(hook_user, false);
    }

    public hook_user createhook_user(long userID) {
        return hook_userPersistence.create(userID);
    }

    public void deletehook_user(long userID)
        throws PortalException, SystemException {
        hook_userPersistence.remove(userID);
    }

    public void deletehook_user(hook_user hook_user) throws SystemException {
        hook_userPersistence.remove(hook_user);
    }

    public List<Object> dynamicQuery(DynamicQuery dynamicQuery)
        throws SystemException {
        return hook_userPersistence.findWithDynamicQuery(dynamicQuery);
    }

    public List<Object> dynamicQuery(DynamicQuery dynamicQuery, int start,
        int end) throws SystemException {
        return hook_userPersistence.findWithDynamicQuery(dynamicQuery, start,
            end);
    }

    public hook_user gethook_user(long userID)
        throws PortalException, SystemException {
        return hook_userPersistence.findByPrimaryKey(userID);
    }

    public List<hook_user> gethook_users(int start, int end)
        throws SystemException {
        return hook_userPersistence.findAll(start, end);
    }

    public int gethook_usersCount() throws SystemException {
        return hook_userPersistence.countAll();
    }

    public hook_user updatehook_user(hook_user hook_user)
        throws SystemException {
        hook_user.setNew(false);

        return hook_userPersistence.update(hook_user, true);
    }

    public hook_user updatehook_user(hook_user hook_user, boolean merge)
        throws SystemException {
        hook_user.setNew(false);

        return hook_userPersistence.update(hook_user, merge);
    }

    public hook_activityLocalService gethook_activityLocalService() {
        return hook_activityLocalService;
    }

    public void sethook_activityLocalService(
        hook_activityLocalService hook_activityLocalService) {
        this.hook_activityLocalService = hook_activityLocalService;
    }

    public hook_activityService gethook_activityService() {
        return hook_activityService;
    }

    public void sethook_activityService(
        hook_activityService hook_activityService) {
        this.hook_activityService = hook_activityService;
    }

    public hook_activityPersistence gethook_activityPersistence() {
        return hook_activityPersistence;
    }

    public void sethook_activityPersistence(
        hook_activityPersistence hook_activityPersistence) {
        this.hook_activityPersistence = hook_activityPersistence;
    }

    public hook_categoryLocalService gethook_categoryLocalService() {
        return hook_categoryLocalService;
    }

    public void sethook_categoryLocalService(
        hook_categoryLocalService hook_categoryLocalService) {
        this.hook_categoryLocalService = hook_categoryLocalService;
    }

    public hook_categoryService gethook_categoryService() {
        return hook_categoryService;
    }

    public void sethook_categoryService(
        hook_categoryService hook_categoryService) {
        this.hook_categoryService = hook_categoryService;
    }

    public hook_categoryPersistence gethook_categoryPersistence() {
        return hook_categoryPersistence;
    }

    public void sethook_categoryPersistence(
        hook_categoryPersistence hook_categoryPersistence) {
        this.hook_categoryPersistence = hook_categoryPersistence;
    }

    public hook_taglistLocalService gethook_taglistLocalService() {
        return hook_taglistLocalService;
    }

    public void sethook_taglistLocalService(
        hook_taglistLocalService hook_taglistLocalService) {
        this.hook_taglistLocalService = hook_taglistLocalService;
    }

    public hook_taglistService gethook_taglistService() {
        return hook_taglistService;
    }

    public void sethook_taglistService(hook_taglistService hook_taglistService) {
        this.hook_taglistService = hook_taglistService;
    }

    public hook_taglistPersistence gethook_taglistPersistence() {
        return hook_taglistPersistence;
    }

    public void sethook_taglistPersistence(
        hook_taglistPersistence hook_taglistPersistence) {
        this.hook_taglistPersistence = hook_taglistPersistence;
    }

    public hook_userLocalService gethook_userLocalService() {
        return hook_userLocalService;
    }

    public void sethook_userLocalService(
        hook_userLocalService hook_userLocalService) {
        this.hook_userLocalService = hook_userLocalService;
    }

    public hook_userService gethook_userService() {
        return hook_userService;
    }

    public void sethook_userService(hook_userService hook_userService) {
        this.hook_userService = hook_userService;
    }

    public hook_userPersistence gethook_userPersistence() {
        return hook_userPersistence;
    }

    public void sethook_userPersistence(
        hook_userPersistence hook_userPersistence) {
        this.hook_userPersistence = hook_userPersistence;
    }

    protected void runSQL(String sql) throws SystemException {
        try {
            PortalUtil.runSQL(sql);
        } catch (Exception e) {
            throw new SystemException(e);
        }
    }
}
